        <div class="body-wrap">
        <div class="top-tools">
            <a class="inner-link" href="#Ext.data.XmlReader-props"><img src="../resources/images/default/s.gif" class="item-icon icon-prop">Properties</a>
            <a class="inner-link" href="#Ext.data.XmlReader-methods"><img src="../resources/images/default/s.gif" class="item-icon icon-method">Methods</a>
            <a class="inner-link" href="#Ext.data.XmlReader-events"><img src="../resources/images/default/s.gif" class="item-icon icon-event">Events</a>
                            <a class="inner-link" href="#Ext.data.XmlReader-configs"><img src="../resources/images/default/s.gif" class="item-icon icon-config">Config Options</a>
                        <a class="bookmark" href="../docs/?class=Ext.data.XmlReader"><img src="../resources/images/default/s.gif" class="item-icon icon-fav">Direct Link</a>
        </div>
                <div class="inheritance res-block">
<pre class="res-block-inner"><a ext:cls="Ext.data.DataReader" ext:member="" href="output/Ext.data.DataReader.html">DataReader</a>
  <img src="resources/elbow-end.gif"/>XmlReader</pre></div>
                <h1>Class Ext.data.XmlReader</h1>
        <table cellspacing="0">
            <tr><td class="label">Package:</td><td class="hd-info">Ext.data</td></tr>
            <tr><td class="label">Defined In:</td><td class="hd-info"><a href="../source/data/XmlReader.js" target="_blank">XmlReader.js</a></td></tr>
            <tr><td class="label">Class:</td><td class="hd-info">XmlReader</td></tr>
                                    <tr><td class="label">Extends:</td><td class="hd-info"><a ext:cls="Ext.data.DataReader" ext:member="" href="output/Ext.data.DataReader.html">DataReader</a></td></tr>
                    </table>
        <div class="description">
            Data reader class to create an Array of <a ext:cls="Ext.data.Record" href="output/Ext.data.Record.html">Ext.data.Record</a> objects from an XML document
based on mappings in a provided Ext.data.Record constructor.<br><br>
<p>
<em>Note that in order for the browser to parse a returned XML document, the Content-Type
header in the HTTP response must be set to "text/xml".</em>
<p>
Example code:
<pre><code>var Employee = Ext.data.Record.create([
   {name: <em>'name'</em>, mapping: <em>'name'</em>},     <i>// <em>"mapping"</em> property not needed <b>if</b> it's the same as <em>"name"</em></i>
   {name: <em>'occupation'</em>}                 <i>// This field will use <em>"occupation"</em> as the mapping.</i>
]);
<b>var</b> myReader = <b>new</b> Ext.data.XmlReader({
   totalRecords: <em>"results"</em>, <i>// The element which contains the total dataset size (optional)</i>
   record: <em>"row"</em>,           <i>// The repeated element which contains row information</i>
   id: <em>"id"</em>                 <i>// The element within the row that provides an ID <b>for</b> the record (optional)</i>
}, Employee);</code></pre>
<p>
This would consume an XML file like this:
<pre><code>&lt;?xml?>
&lt;dataset>
 &lt;results>2&lt;/results>
 &lt;row>
   &lt;id>1&lt;/id>
   &lt;name>Bill&lt;/name>
   &lt;occupation>Gardener&lt;/occupation>
 &lt;/row>
 &lt;row>
   &lt;id>2&lt;/id>
   &lt;name>Ben&lt;/name>
   &lt;occupation>Horticulturalist&lt;/occupation>
 &lt;/row>
&lt;/dataset></code></pre>        </div>
        
        <div class="hr"></div>
                <a id="Ext.data.XmlReader-configs"></a>
        <h2>Config Options</h2>
        <table cellspacing="0" class="member-table">
            <tr>
                <th class="sig-header" colspan="2">Config Options</th>
                <th class="msource-header">Defined By</th>
            </tr>
                <tr class="config-row">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.data.XmlReader-id"></a>
            <b>id</b> : String            <div class="mdesc">
                            The DomQuery path relative from the record element to the element that contains a record identifier value.                        </div>
        </td>
        <td class="msource">XmlReader</td>
    </tr>
        <tr class="config-row alt">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.data.XmlReader-record"></a>
            <b>record</b> : String            <div class="mdesc">
                            The DomQuery path to the repeated element which contains record information.                        </div>
        </td>
        <td class="msource">XmlReader</td>
    </tr>
        <tr class="config-row">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.data.XmlReader-success"></a>
            <b>success</b> : String            <div class="mdesc">
                            The DomQuery path to the success attribute used by forms.                        </div>
        </td>
        <td class="msource">XmlReader</td>
    </tr>
        <tr class="config-row alt expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.data.XmlReader-totalRecords"></a>
            <b>totalRecords</b> : String            <div class="mdesc">
                        <div class="short">The DomQuery path from which to retrieve the total number of records in the dataset. This is only needed if the whole...</div>
            <div class="long">
                The DomQuery path from which to retrieve the total number of records in the dataset. This is only needed if the whole dataset is not passed in one go, but is being paged from the remote server.            </div>
                        </div>
        </td>
        <td class="msource">XmlReader</td>
    </tr>
            </table>
                <a id="Ext.data.XmlReader-props"></a>
        <h2>Public Properties</h2>
                <table cellspacing="0" class="member-table">
            <tr>
                <th class="sig-header" colspan="2">Property</th>
                <th class="msource-header">Defined By</th>
            </tr>
                <tr class="property-row inherited">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.data.XmlReader-meta"></a>
            <b>meta</b> : Mixed            <div class="mdesc">
                            This DataReader's configured metadata as passed to the constructor.                        </div>
        </td>
        <td class="msource"><a ext:cls="Ext.data.DataReader" ext:member="#meta" href="output/Ext.data.DataReader.html#meta">DataReader</a></td>
    </tr>
        <tr class="property-row alt">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.data.XmlReader-xmlData"></a>
            <b>xmlData</b> : XMLDocument            <div class="mdesc">
                            After any data loads/reads, the raw XML Document is available for further custom processing.                        </div>
        </td>
        <td class="msource">XmlReader</td>
    </tr>
            </table>
                <a id="Ext.data.XmlReader-methods"></a>
        <h2>Public Methods</h2>
                <table cellspacing="0" class="member-table">
            <tr>
                <th class="sig-header" colspan="2">Method</th>
                <th class="msource-header">Defined By</th>
            </tr>
                <tr class="method-row expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.data.XmlReader-XmlReader"></a>
            <b>XmlReader</b>(&nbsp;<code>Object meta</code>, <code>Object recordType</code>&nbsp;)            <div class="mdesc">
                        <div class="short">Create a new XmlReader.</div>
            <div class="long">
                Create a new XmlReader.    <div class="mdetail-params">
        <strong>Parameters:</strong>
        <ul><li><code>meta</code> : Object<div class="sub-desc">Metadata configuration options</div></li><li><code>recordType</code> : Object<div class="sub-desc">Either an Array of field definition objects as passed to
<a ext:cls="Ext.data.Record" ext:member="create" href="output/Ext.data.Record.html#create">Ext.data.Record.create</a>, or a Record constructor object created using <a ext:cls="Ext.data.Record" ext:member="create" href="output/Ext.data.Record.html#create">Ext.data.Record.create</a>.</div></li>        </ul>
        <strong>Returns:</strong>
        <ul>
            <li><code></code></li>
        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource">XmlReader</td>
    </tr>
        <tr class="method-row alt expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.data.XmlReader-read"></a>
            <b>read</b>(&nbsp;<code>Object response</code>&nbsp;) : Object            <div class="mdesc">
                        <div class="short">This method is only used by a DataProxy which has retrieved data from a remote server.</div>
            <div class="long">
                This method is only used by a DataProxy which has retrieved data from a remote server.    <div class="mdetail-params">
        <strong>Parameters:</strong>
        <ul><li><code>response</code> : Object<div class="sub-desc">The XHR object which contains the parsed XML document. The response is expected
to contain a property called <tt>responseXML</tt> which refers to an XML document object.</div></li>        </ul>
        <strong>Returns:</strong>
        <ul>
            <li><code>Object</code><div class="sub-desc">records A data block which is used by an {@link Ext.data.Store} as a cache of Ext.data.Records.</div></li>
        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource">XmlReader</td>
    </tr>
        <tr class="method-row expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.data.XmlReader-readRecords"></a>
            <b>readRecords</b>(&nbsp;<code>Object doc</code>&nbsp;) : Object            <div class="mdesc">
                        <div class="short">Create a data block containing Ext.data.Records from an XML document.</div>
            <div class="long">
                Create a data block containing Ext.data.Records from an XML document.    <div class="mdetail-params">
        <strong>Parameters:</strong>
        <ul><li><code>doc</code> : Object<div class="sub-desc">A parsed XML document.</div></li>        </ul>
        <strong>Returns:</strong>
        <ul>
            <li><code>Object</code><div class="sub-desc">records A data block which is used by an {@link Ext.data.Store} as a cache of Ext.data.Records.</div></li>
        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource">XmlReader</td>
    </tr>
            </table>
                <a id="Ext.data.XmlReader-events"></a>
        <h2>Public Events</h2>
        <div class="no-members">This class has no public events.</div>
        </div>